{extend name="public:base" /}

{block name="content"}
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <a href="{:url('doGoodsGift')}" class="btn btn-primary btn-lg">发布赠品</a>

                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="fa fa-chevron-up"></i>
                        </a>
                    </div>
                </div>

                <div class="ibox-content">
                    <div class="row search-form">
                        <div class="col-sm-2 m-b-sm">
                            <div class="input-group">
                                <input type="text" class="form-control form-control-lg" placeholder="请输入搜索内容" name="gift_name" value="{:input('gift_name')}">
                            </div>
                        </div>
                        <div class="col-sm-2 m-b-sm">
                            <div class="input-group">
                                <button type="button" class="btn btn-primary btn-lg screen-btn">搜索</button>
                            </div>
                        </div>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-striped">
                            <thead>
                            <tr>
                                <th>ID</th>
                                <th>赠品名称</th>
                                <th>赠品价格</th>
                                <th>赠品赠送开始日期</th>
                                <th>赠品赠送结束日期</th>
                                <th>创建时间</th>
                                <th>修改时间</th>
                                <th>操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            {volist name="list" id="vo"}
                            <tr>
                                <td>{$vo.id}</td>
                                <td>{$vo.gift_name}</td>
                                <td>{$vo.gift_price}</td>
                                <td>{$vo.start_date}</td>
                                <td>{$vo.end_date}</td>
                                <td>{:timeFormat($vo.create_time)}</td>
                                <td>{:timeFormat($vo.update_time)}</td>
                                <td class="project-actions">
                                    <a href="{:url('doGoodsGift', ['id' => $vo.id])}" class="btn btn-white btn-sm">
                                        <i class="fa fa-edit"></i> 详情
                                    </a>
                                    <a href="{:url('delGoodsGiftList', ['id' => $vo.id])}" class="btn btn-white btn-sm ajax-del">
                                        <i class="fa fa-edit"></i> 删除
                                    </a>
                                </td>
                            </tr>
                            {/volist}
                            </tbody>
                        </table>
                        {if !empty($list->items())}{$list->render()}{/if}
                    </div>

                </div>
            </div>
        </div>

    </div>
</div>

{/block}

